﻿using System.Collections.Generic;

namespace DataBase.DBmodels;

/// <summary>
/// 角色权限表
/// </summary>
public partial class RolePermission
{
    /// <summary>
    /// 主键，自动递增
    /// </summary>
    public int RoleId { get; set; }

    /// <summary>
    /// 权限名称
    /// </summary>
    public string PermissionName { get; set; } = null!;

    /// <summary>
    /// 权限编码
    /// </summary>
    public string PermissionCode { get; set; } = null!;

    /// <summary>
    /// 按钮控件名称
    /// </summary>
    public string? ControlName { get; set; }

    /// <summary>
    /// 权限等级，普通用户是3，admin是2，administrator是1
    /// </summary>
    public int RoleLevel { get; set; }

    public virtual ICollection<UserRoleRelation> UserRoleRelations { get; set; } = new List<UserRoleRelation>();
}
